package com.myway.controller;

import com.myway.dto.common.JsonData;
import com.myway.pojo.PassengeQuestion;
import com.myway.service.PQuestionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;


@RequestMapping("/en/quest")
@Controller
public class PQuestionController {

    @Autowired
    private PQuestionService pQuestionService;

    @RequestMapping("/add")
    @ResponseBody
    public JsonData addPQuestions(PassengeQuestion passengeQuestion){
        pQuestionService.addPQuestion(passengeQuestion);
        return JsonData.success();
    }
}
